package com.iot.openfeign;

import com.dc3.common.bean.R;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestParam;
import reactivefeign.spring.config.ReactiveFeignClient;
import reactor.core.publisher.Mono;

import java.util.List;
import java.util.Map;

/**
 * @Author 咕唧
 * @Date 2022/7/18 16:28
 * @Version 1.0
 */
@ReactiveFeignClient(value = "iot-tenant")
public interface TenantClient {
    @PostMapping("/tenant/usercounts")
    Mono<R> getCountByTentIdAndUserIds(@RequestBody List<String> userIds, @RequestParam("tenantId") String tenantId);

    @PostMapping("/tenant/binduser")
    Mono<R<Object>> bindUser2Tenant(@RequestBody Map dc3TenantBind);
}
